/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package org.trandio.dao;

import java.sql.SQLException;
import java.util.List;
import javax.naming.NamingException;
import org.trandio.model.ActividadContratadaVO;
import org.trandio.model.ActividadVO;
import org.trandio.model.ContratoVO;
import org.trandio.model.GrupoActividadVO;

/**
 *
 * @author root
 */
public interface ContratoInterface {

    /**
     * Metodo que permite agregar una actividad a la base de datos
     * @param actividadVO ActividadVO
     */
  

    public List<ContratoVO> consultarContratos() throws SQLException, NamingException;

    public List<ContratoVO> consultarContrato(ContratoVO contratoVO) throws SQLException, NamingException;

    public ContratoVO getContrato(int id) throws SQLException, NamingException;
    
    

    public String borrarContrato(int id) throws SQLException, NamingException;

    public int guardarContrato(ContratoVO contratoVO) throws SQLException, NamingException;

    public void guardarContratoEdit(ContratoVO contratoVO) throws SQLException, NamingException;

    public void contratarActividad(int id, int id_actividad) throws SQLException, NamingException;

    public List<ActividadContratadaVO> consultarActividadesContratadas(int id_contrato) throws SQLException, NamingException;

    public List<ActividadVO> consultarActividadesHabilitadas(String codigo,int grupo, int contrato) throws SQLException, NamingException;

    public void descontratarActividad(int id, int id_actividad) throws SQLException, NamingException;

    public List<ContratoVO> consultarContrato(String codigo, String descripcion, int firstRow, int rowsPerPage, String sortField, boolean sortAscending) throws SQLException, NamingException;

    public int count() throws SQLException, NamingException;

    public ContratoVO getContratoEntidad(int id_entidad) throws SQLException, NamingException;
    public ContratoVO getContratoEntidad(int id_entidad, int id_contrato) throws SQLException, NamingException;
    
    public ContratoVO getContratoPypEntidad(int id_entidad) throws SQLException, NamingException;

    public List<GrupoActividadVO> consultarGrupoContratado(int id) throws SQLException, NamingException;

    public void asignarCopagosGrupo(String idgrupo, String idcto, String idcopago) throws SQLException, NamingException;

    public List<ContratoVO> consultarContrato(String codigo, String descripcion) throws SQLException, NamingException;
    public List<ContratoVO> getContratoEntidadFacturacion(int entidad) throws SQLException, NamingException;

    public List<ActividadContratadaVO> consultarActividadesContratadas(int parseInt, int first, int limit, String codact, int grupo) throws SQLException, NamingException;

    public int contarContratadas(int idContrato) throws SQLException, NamingException;


    //public void contratarGrupo(int id, int grupoact) throws SQLException, NamingException;

    public void descontratarGrupo(int idCont, int idGrupo) throws SQLException, NamingException;

    public GrupoActividadVO getCopagosGrupo(int idgrupo, int cto) throws SQLException, NamingException ;

    public int getCantContratos(String $sWhere) throws SQLException, NamingException;

    public List<ContratoVO> getContratos(int displayStart, int displayLength, String $sWhere, String orden) throws SQLException, NamingException;
    
    public ContratoVO getContratoPyp(int id_contrato) throws SQLException, NamingException;
    
   
}
